package cn.wusifx.zabbix.request.builder.item;

import cn.wusifx.zabbix.request.BaseRequest;
import cn.wusifx.zabbix.request.builder.UpdateRequestBuilder;

import java.util.Map;

/**
 * https://www.zabbix.com/documentation/4.0/manual/api/reference/itemprototype/update
 */
public class ItemPrototypeUpdateRequestBuilder extends UpdateRequestBuilder {
    private String itemId;
    public ItemPrototypeUpdateRequestBuilder(String auth) {
        super("itemprototype.update", auth);
    }

    public ItemPrototypeUpdateRequestBuilder(Long id, String auth) {
        super("itemprototype.update", id, auth);
    }

    public String getItemId() {
        return itemId;
    }

    public ItemPrototypeUpdateRequestBuilder setItemId(String itemId) {
        this.itemId = itemId;
        return this;
    }

    @Override
    public BaseRequest<Map<String, Object>> builder() {
        baseRequest.getParams().put("itemId",itemId);
        return baseRequest;
    }
}
